#include "thread_pool.h"
#include <chrono>

void func(void *arg)
{
    int *i = (int*)arg;
    std::cout << "\t\tfunc:" << *i << std::endl;
}


int main()
{
    ThreadPool pool(4);

    int a = 1;
    pool.push_tash(&func, &a);
    int b = 2;
    pool.push_tash(&func, &b);
    int c = 3;
    pool.push_tash(&func, &c);
    int d = 4;
    pool.push_tash(&func, &d);
    int e = 5;
    pool.push_tash(&func, &e);
    int f = 6;
    pool.push_tash(&func, &f);
    std::this_thread::sleep_for(std::chrono::seconds(1));
}